package com.loginer.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.Map;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.bwie.common.utils.PageUtils;
import com.bwie.common.utils.Query;

import com.loginer.dao.ShoperDao;
import com.loginer.entity.ShoperEntity;
import com.loginer.service.ShoperService;


@Service("shoperService")
public class ShoperServiceImpl extends ServiceImpl<ShoperDao, ShoperEntity> implements ShoperService {

    @Autowired
    private ShoperDao shoperDao;

    @Override
    public PageUtils queryPage(Map<String, Object> params) {
        IPage<ShoperEntity> page = this.page(
                new Query<ShoperEntity>().getPage(params),
                new QueryWrapper<ShoperEntity>()
        );

        return new PageUtils(page);
    }

    @Override
    public ShoperEntity shoperLogin(ShoperEntity shoperEntity) {
        return shoperDao.shoperLogin(shoperEntity);
    }

}